<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
	</head>
	<body>
	</body>
</html>
<script>
	var num=100,name="王芳";
	document.write("函数外num="+num+",name="+name);
	function example(){
		var num=200;
		document.write("函数内num="+num+",name="+name);
	}
	example();
</script>